package main.service;

import java.io.Serializable;
import java.util.List;

import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;

//@Service
@Transactional(propagation=Propagation.REQUIRED)
public interface IBaseService<T> {
	T getByID(Class<T> entityClass, Serializable ID);
	List<T> loadAll(Class<T> entityClass);
	@Transactional(propagation=Propagation.REQUIRED)
	Integer save(T entity);
	@Transactional(propagation=Propagation.REQUIRED)
	Boolean update(T entity);
	@Transactional(propagation=Propagation.REQUIRED)
	Boolean remove(T entity);
}
